package com.rapid.maintenance.adapter;

import androidx.annotation.NonNull;

import com.chad.library.adapter.base.BaseViewHolder;
import com.rapid.maintenance.R;
import com.rapid.maintenance.base.BaseAdapter;

/**
 *
 */
public class BiddingDetailsAdapter extends BaseAdapter<Object> {
    private boolean isPublisher;

    public BiddingDetailsAdapter(boolean isPublisher) {
        super(R.layout.item_bidding_details);
        this.isPublisher = isPublisher;
    }

    @Override
    protected void convert(@NonNull BaseViewHolder helper, Object item) {
        helper.setGone(R.id.tv_dec, isPublisher)
                .setGone(R.id.tv_label, isPublisher)
                .setGone(R.id.tv_file, isPublisher)
                .setGone(R.id.tv_hide, !isPublisher);
    }
}
